import request from "@/utils/request";

// 查询防火墙列表
export function listFirewall(query) {
  return request({
    url: "/experiment/firewall/list",
    method: "get",
    params: query,
  });
}

// 查询防火墙详细
export function getFirewall(firewallId) {
  return request({
    url: "/experiment/firewall/" + firewallId,
    method: "get",
  });
}

// 新增防火墙
export function addFirewall(data) {
  return request({
    url: "/experiment/firewall",
    method: "post",
    data: data,
  });
}

// 修改防火墙
export function updateFirewall(data) {
  return request({
    url: "/experiment/firewall",
    method: "put",
    data: data,
  });
}

// 删除防火墙
export function delFirewall(firewallId) {
  return request({
    url: "/experiment/firewall/" + firewallId,
    method: "delete",
  });
}

// 获取策略列表
export function getFirewallPolicy() {
  return request({
    url: "/experiment/strategy/getList",
    method: "get",
  });
}
